<template>
  <div class="bannerliststyle">
    <!-- 标题 -->
    <h2>{{ datas.text }}</h2>
    <!-- 类型选择 -->
    <div class="placeHolderstyle">
      <p>选择链接：</p>
      <div class="opText">
        <select-link @selectThisLink="selectThisLink" @clearThisLink="clearThisLink" :linktypeurl="datas.apiUrl" />
      </div>
      <div class="isub">
        <span>是否是个人中心:</span>
        <el-radio-group v-model="datas.isShowPerson">
          <el-radio :label="1">是</el-radio>
          <el-radio :label="0">否</el-radio>
        </el-radio-group>
      </div>
    </div>
  </div>
</template>

<script>
import SelectLink from "../../selectLink";
export default {
  name: "Bannerliststyle",
  components: { 
    SelectLink 
  },
  props: {
    datas: Object,
  },
  data() {
    return {
      interurl: ""
    };
  },
  methods: {
    selectThisLink(resu) {
      this.datas.apiUrl = resu.url;
    },
    clearThisLink () {
      this.datas.apiUrl = '';
    }
  },
  mounted() {
    this.interurl = this.datas.apiUrl || '';
  },
};
</script>

<style scoped lang="scss">
.bannerliststyle {
  width: 100%;
  position: absolute;
  left: 0;
  top: 0;
  padding: 0 10px 20px;
  box-sizing: border-box;
  /* 标题 */
  h2 {
    padding: 24px 16px 24px 0;
    margin-bottom: 15px;
    border-bottom: 1px solid #f2f4f6;
    font-size: 18px;
    font-weight: 600;
    color: #323233;
  }
  .placeHolderstyle {
    padding: 20px 0;
    p {
      display: block;
      margin-bottom: 10px;
    }
    .isub{
      margin-top:10px;
    }
  }
}
</style>
